/*
	dos.h

	Borland header for compatibility under linux
*/

/*
 *      C/C++ Run Time Library - Version 1.0
 *
 *      Copyright (c) 2002 by Borland Software Corporation
 *      All Rights Reserved.
 *
 */


#ifndef __DOS_H
#define __DOS_H

#ifndef ___DEFS_H
#include <_defs.h>
#endif

#include <dir.h>

#ifdef __cplusplus
extern "C" {
#endif

#ifndef __ARGV_DEFINED
#define __ARGV_DEFINED
extern int _argc;
extern char** _argv;
#define __argc _argc
#define __argv _argv
#endif

/** Note: _rtl_mstick returns a 32-bit value that is the number of milliseconds
	since the unix epoch (1/1/1970) truncated to fit into 32-bits.  This is a
	good general purpose millisecond resolution timer source.
*/
unsigned long _rtl_mstick(void);

/** Note: _rtl_ustick returns a 64-bit value that is the number of microseconds
	since the unix epoch (1/1/1970).  This is a good general purpose microsecond
	resolution timer source.
*/
unsigned __int64 _rtl_ustick(void);

/* Some handy global version variables */

extern unsigned char  _osmajor;
extern unsigned char  _osminor;
extern unsigned short _ossubminor;
extern unsigned char  _osmode;
extern unsigned int   _osversion;
extern char *         _osversionstr;
extern unsigned int   _version;
extern unsigned int   _rtlversion;
extern unsigned int   _libcversion;

#ifndef __ENVIRON_DEFINED
#define __ENVIRON_DEFINED
extern char **__environ;
#define _environ __environ
#endif

#ifdef __cplusplus
} /* "C" */
#endif


#endif /* __DOS_H */
